package com.sc.sc250601.cook.mapper;

import com.sc.sc250601.cook.pojo.Comment;
import com.sc.sc250601.cook.pojo.CommentDTO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CommentMapper {
    List<Comment> selectByTargetTypeAndId(@Param("tid") Long targetId);
    int deleteByPrimaryKey(Long id);

    int insert(Comment record);

    int insertSelective(Comment record);

    Comment selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Comment record);

    int updateByPrimaryKeyWithBLOBs(Comment record);

    int updateByPrimaryKey(Comment record);

    List<CommentDTO> selectCommentsWithUser(@Param("targetType")Integer targetType, @Param("targetId")Long targetId);
}